#include <stdio.h>
#include <math.h>
int main()
{
	int n;
	scanf("%d",&n);
	if (0 == n)
	{
		printf("NO\n");
		return 0;
	}
	int x;
	x = (int)(log2(n)/log2(4) + 1e-8);
	printf("%s\n",fabs(pow(4,x) - n) < 1e-8 ? "YES" : "NO");
	return 0;
}


#include <stdio.h>
int main()
{
	int fib[100];
	int n;
	fib[0] = 0;
	fib[1] = 1;
	scanf("%d",&n);
	for(int i = 2; i <= n; ++i)
	{
		fib[i] = fib[i - 1] + fib[i - 2];
	}
	printf("%d\n",fib[n - 1]);
	return 0;
}


